#include "Matrix44.h"
#include "Vector2.h"
#include "util/Helper.h"
#include "foundation/PxVec3.h"


using namespace Boon;
using namespace physx;


Boon::Matrix44::Matrix44()
	: PxMat44( PxMat44::createIdentity() )
{

}

Boon::Matrix44::Matrix44( const Matrix44& o )
	: PxMat44( o )
{

}

void Boon::Matrix44::Rotate( float angle )
{
	rotate( PxVec3( 0, 0, 1 * angle ) );
}

void Boon::Matrix44::Translate( const Vector3& v )
{
	setPosition( transform( PxVec3( v.x, v.y, v.z ) ) );
}

const Vector3 Boon::Matrix44::GetPosition() const
{
	PxVec3 pos( this->getPosition() );
	return Vector3( pos.x, pos.y, pos.z );
}

void Boon::Matrix44::SetPosition( const Vector3& position )
{
	setPosition( position );
}
